package com.lokyiu.mybible.db.sqlite.def;

import android.database.sqlite.SQLiteDatabase;

public class VerseColumns implements Columns {

	/**
	 * ------------- VERSES Table
	 */
	public static final String TABLENAME = "verses";
	public static final String VERSES_BIBLEBOOK = "bookname";
	public static final String VERSES_CHPATER_NUMBER = "chapternum";
	public static final String VERSES_NUMBER = "versenum";
	public static final String VERSES_CONTENT = "contents";
	public static final String CREATE_VERSES_TABLE_SQL = "create table "
			+ TABLENAME + "(" + VERSES_BIBLEBOOK + " TEXT,"
			+ VERSES_CHPATER_NUMBER + " INT," + VERSES_NUMBER + " INT,"
			+ VERSES_CONTENT + " TEXT" + ", PRIMARY KEY(" + VERSES_BIBLEBOOK + "," + VERSES_CHPATER_NUMBER + "," + VERSES_NUMBER +"))";

	@Override
	public void onCreate(SQLiteDatabase db) {
		db.execSQL(CREATE_VERSES_TABLE_SQL);
	}

	@Override
	public void dropTable(SQLiteDatabase db) {
		db.execSQL("DROP TABLE IF EXISTS " + TABLENAME);
	}

	@Override
	public String getTableName() {
		return TABLENAME;
	}

}
